﻿using System.ComponentModel;
using System.Data;
using System.Windows;
namespace WPFExcelReport
{
    public partial class TMCO07
    {
        public TMCO07()
        {
            if (DesignerProperties.GetIsInDesignMode(this))
                return;
            MV = new VICC_ABAUFM();
            DataContext = MV;
            InitializeComponent();
        }
        public override void OnEXAUFChg(string vlaue)
        {
            if (!IsCanLoad)
                return;
            TBMain.Clear();
            if (vlaue == "")
                return;
            dwData = TBMain.NewRow();
            string ordertype = vlaue.Substring(0, 1);
            dwData["ABAVKAUFTYP"] = vlaue.Substring(0, 1);
            dwData["ABAVKAUFKRS"] = vlaue.Substring(1, 2);
            dwData["ABAVKAUFLFD"] = vlaue.Substring(3, 6);
            dwData["ABAVKAUFPOS"] = vlaue.Substring(9, 3);
            dwData["MTYPE"] = MTYPE.PadRight(1);
            SResult = TMV.QMUX03(dwData);
            MergeData(SResult);
            if (TBMain.Rows.Count > 0)
                IsShowGrid = true;
            base.OnEXAUFChg(vlaue);
        }
    }
}
